#include <bits/stdc++.h>
using namespace std;
#define yes cout<<"YES"<<endl
#define no cout<<"NO"<<endl
using ll = long long;
void solve()
{
    string w = "whiile";
    ll ans = 0;
    string s;
    cin >> s;

    for (size_t i = 0; i < w.size();++i)
    {
        if(s[i]!=w[i])
        {
            ans++;
        }
    }
    cout << ans;
}
int main()
{
    int t = 1;
    //cin >> t;
    while(t--)
    {
        solve();
    }
   return 0;
}
